#include <iostream>
#include <unistd.h>
int main() {
    pid_t pid,ppid;
    pid = getpid();
    ppid = getppid();
    std::cout<<"当前进程的ID号为: "<<pid<<"\n";
    std::cout<<"当前进程的父进程ID号为: "<<ppid<<"\n";
}